<%--
  Created by IntelliJ IDEA.
  User: finder
  Date: 2021/10/11
  Time: 9:51
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
  <title>Login</title>
</head>
<style>
  table {
    border: black 1px solid;
    height: 200px;
    width: 400px;
    position: absolute;
    top: 20%;
    left: 60%;
  }
  h1 {
    color: red;
    text-align: center;
  }
</style>
<body>
<h1>${requestScope.msg}</h1>
<form action="UserServlet" method="post">
  <input type="hidden" name="flag" value="login">
  <table>
    <tr>
      <td> 用户名：</td>
      <td><input type="text" name="username" value="${cookie.get("username").value}"></td>
    </tr>
    <tr>
      <td>密码：</td>
      <td><input type="password" name="password" value="${cookie.get("password").value}"></td>
    </tr>
    <tr>
      <td></td>
      <td>
        记住密码<input type="checkbox" name="rem" ${cookie.get("rem")!=null?"checked":""}>
      </td>
    </tr>
    <tr>
      <td><input type="submit" value="登录"></td>
      <td>
        <input type="button" value="注册" onclick="location.href='register.jsp'">
      </td>
    </tr>
  </table>
</form>
</body>
</html>
